package com.CmJava.service;

import com.CmJava.entity.ResultEntity;
import com.CmJava.entity.blog.Blog;
import com.CmJava.entity.blog.BlogModel;
import com.CmJava.entity.blog.BlogRedis;

public interface BlogService {
    ResultEntity getBlogList(String keyWord, String currentPage, int pageNum);

    ResultEntity getRecentBlog(int i, int i1);

    ResultEntity getNewBlogId();

    ResultEntity addBlogRedis(String key, String blogRedisData);

    ResultEntity addBlogMysql(Blog blog);

    ResultEntity getBlogMysql(String blogId);

    ResultEntity getBlogRedis(String key);

    ResultEntity getBlogModelAndChildNum(String key);

    ResultEntity updateBlogMysql(Blog blog);

    ResultEntity updateThisBlogModle(String key, String modelId, BlogModel blogModel);

    ResultEntity getAdminBlogList();

    ResultEntity addBlogCommentMysql(String blogId);

    void blogVisitNumIncrement(String blogId);

    ResultEntity deleteBlogModel(String blogId, int modelIndex);

    ResultEntity deleteBlogChildModel(String blogId, int modelIndex, int childIndex);

    ResultEntity backupBlog(String blogId);

    ResultEntity downBackupBlog();
}
